#################################################################################
## Copyright 2006 Kervin L. Pierre
##     EMAIL: otlkcon@adevsoft.com
## 
## This file is part of Otlkcon.
##
## Otlkcon is free software; you can redistribute it and/or modify
## it under the terms of the GNU Lesser General Public License as published by
## the Free Software Foundation; either version 2.1 of the License, or
## (at your option) any later version.
## 
## Otlkcon is distributed in the hope that it will be useful,
## but WITHOUT ANY WARRANTY; without even the implied warranty of
## MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
## Lesser GNU General Public License for more details.
## 
## You should have received a copy of the Lesser GNU General Public License
## along with Otlkcon; if not, write to the Free Software
## Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
## 
##################################################################################

WIX_DIR=C:\Program Files\WiX

CANDLE_EXE="$(WIX_DIR)\candle.exe"
LIGHT_EXE="$(WIX_DIR)\light.exe"
#WIX_UILIB="$(WIX_DIR)\ui\wixui_mondo.wixlib"
WIX_UILIB="$(WIX_DIR)\wixui.wixlib"
WIX_LOCAL_STRING="$(WIX_DIR)\WixUI_en-us.wxl"
CP=copy /Y
RM=del

all: copyfiles compile link
     
compile:
    $(CANDLE_EXE) otlkcon.wxs
    
copyfiles:
    $(CP) ..\$(CONFIG)\ochelper.exe .
    $(CP) ..\$(CONFIG)\mstore32.dll .
    $(CP) ..\$(CONFIG)\smlog.dll .
    $(CP) ..\sqlite\$(CONFIG)\ocsqlt32.dll .
    $(CP) ..\otlkcon.ini .
      
link:
    $(LIGHT_EXE) -out $(CONFIG)\openconnector.msi otlkcon.wixobj $(WIX_UILIB) \
            -loc $(WIX_LOCAL_STRING)
    
clean:
    $(RM) *.wixobj *.msi *.dll *.exe *.ini $(CONFIG)\*.msi


